<?php

if(defined("_PARA_DBTABLES"))
    return;
define("_PARA_DBTABLES", 1);

$PARA_TABLES = array(
'account' =>
'(
        uid         int unsigned not null primary key auto_increment,
        screen_name varchar(50) unique,
        pwd_md5     varchar(32),
        email       varchar(80) unique,
        state       char(10),
        group_name  varchar(30),
        msg_count   int unsigned,
        karma       int unsigned not null,
        comment     varchar(200),
        changedate  timestamp default current_timestamp on update current_timestamp,
        createdate  timestamp,
        act_code    varchar(32)
)',

'account_profile' =>
'(
        uid        int unsigned not null primary key,
        full_name  varchar(200),
        gender char(1),
        profile_text text
)',

'forum_thread' =>
'(
       id            int unsigned primary key auto_increment,
       topics        varchar(200),
       state         varchar(10),
       changedate    timestamp default current_timestamp on update current_timestamp,
       createdate    timestamp,
       arch_flag     boolean,
       del_flag      boolean
)',


'forum_index' =>
'(
       id           int unsigned primary key auto_increment,
       thread_id    int unsigned not null,
       parent_id    int unsigned,
       screen_name  varchar(50),
       uid          int unsigned,
       subject      varchar(200),
       date         timestamp,
       ip           char(15),
       tags         varchar(150),
       state        char(10),
       arch_flag    boolean,
       del_flag     boolean
)',



'forum_bodies' =>
'(
       id         int unsigned,
       thread_id  int unsigned,
       body       text,
       arch_flag  boolean,
       del_flag   boolean
)',


'messages' =>
'(
       id       int unsigned primary key auto_increment,
       mid      int unsigned,
       type     char(2),
       date     timestamp,
       ip       char(15),
       descr    varchar(255)
)',

'blocked_ip' =>
'(
       id        int unsigned primary key auto_increment,
       descr     varchar(127),
       message   text,
       status    int unsigned,
       ip1       varchar(7),
       ip2       varchar(7),
       ip3       varchar(7),
       ip4       varchar(7),
       crdate    timestamp,
       moddate   timestamp
)',

'events' =>
'(
       ev_id     int unsigned primary key auto_increment,
       ev_date   timestamp,
       section   varchar(10),
       ev_name   varchar(20),
       meta1     varchar(40),
       meta2     varchar(40)
)',

'chat' =>
'(
        id          int unsigned primary key auto_increment,
        screen_name varchar(50),
        uid         int unsigned,
        text        varchar(250),
        time        timestamp,
        status      char(4),
        ip          char(15)
)',

'chat_arch' =>
'(
        id          int unsigned primary key auto_increment,
        screen_name varchar(50),
        uid         int unsigned,
        text        varchar(250),
        time        timestamp,
        status      char(4),
        ip          char(15)
)',


'linkroll' =>
'(
        id                int unsigned primary key auto_increment,
        url               varchar(250),
        headline          varchar(250),
        subby_screen_name varchar(50),
        subby_uid         int unsigned,
        category_id       int unsigned,
        time              timestamp,
        approved          boolean,
        ip                char(15)
)',


'linkroll_category' =>
'(
        id                int unsigned primary key auto_increment,
        name              varchar(60),
        active            boolean
)',

'config' => 
'(
       type    varchar(20),
       name    varchar(40),
       value   varchar(255)
)',

'ipblock' => 
'(
        id               int unsigned primary key auto_increment,
        name             varchar(60),
        createdate       timestamp,
        definition       varchar(20),
        message          varchar(200),
        block_logged_in  boolean,
        block_viewing    boolean,
        active           boolean
)',

'quotes' => 
'(
        id               int unsigned primary key auto_increment,
        quote            varchar(200),
        name             varchar(60),
        createdate       timestamp,
        active           boolean
)'


);

?>
